package fons.model.ontology.language;

import java.util.Collection;
import java.util.Collections;
import java.util.Set;

import com.google.common.collect.Sets;

public abstract class AbstractNamed implements Named {
	private final Set<String> synonymes = Sets.newHashSet();
	private final String name;
	
	public AbstractNamed(String name) {
		this.name = name;
	}

	@Override
	public Collection<String> getSynonymes() {
		return Collections.unmodifiableSet(synonymes);
	}

	@Override
	public void addSynonyme(String synonyme) {
		this.synonymes.add(synonyme);
	}

	@Override
	public String getName() {
		return name;
	}
}
